package com.tarena.lbs.business.dao.repository;

import com.github.pagehelper.PageInfo;
import com.tarena.lbs.business.pojo.param.UserLocationParam;
import com.tarena.lbs.business.pojo.po.StoreChainPO;
import com.tarena.lbs.business.pojo.po.StorePO;
import com.tarena.lbs.business.pojo.query.AreaStoreQuery;
import com.tarena.lbs.business.pojo.query.StoreChainQuery;
import com.tarena.lbs.business.pojo.query.StoreQuery;
import com.tarena.lbs.business.pojo.vo.StoreVO;

import java.util.List;


public interface StoreRepository {

    void save(StorePO storePO);

    PageInfo<StorePO> pagesList(StoreQuery query);

    PageInfo<StorePO> areaPagesList(AreaStoreQuery query, Integer businessId);

    StorePO getById(Integer id);
    
    /**
     * 根据用户位置查询附近店铺
     * @param param 用户位置参数
     * @return 附近店铺列表
     */
    List<StoreVO> findNearbyStores(UserLocationParam param);

    PageInfo<StoreChainPO> getChain(StoreChainQuery query);

    void delete(Integer id);
}
